# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>

pkgname=hcxkeys
pkgver=6.2.1
pkgrel=2
pkgdesc='Set of tools to generate plainmasterkeys (rainbowtables) and hashes for hashcat and John the Ripper'
url='https://github.com/ZerBea/hcxkeys'
arch=('loong64' 'x86_64')
license=('MIT')
depends=('openssl' 'opencl-driver' 'opencl-icd-loader')
makedepends=('opencl-headers')
source=(https://github.com/ZerBea/hcxkeys/archive/${pkgver}/${pkgname}-${pkgver}.tar.gz
        https://github.com/ZerBea/hcxkeys/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.gz.asc)
sha512sums=('4b6dd57cbe903165ea1fc9ed9e9ba42a1edcedf973c44a24770a54166debd4a500825465a3091310be3fba1bae688258636b5f7ba4ff7554d4c414fa5479cff3'
            'SKIP')
b2sums=('6f7752db7384c06c96e078747f09170a911b55bbf857c60b1b85118a9dccbff7d7c1d6d7324e4e4265b23fcb82a8b219802ac3433b9fa48f3cfb7da4d5af2ea1'
        'SKIP')
validpgpkeys=('5920CE1C567948AFD2C0A9B7375516A45DB88630') # ZeroBeat <ZeroBeat@gmx.de>

build() {
  cd ${pkgname}-${pkgver}
  make PRODUCTION=1
}

package() {
  cd ${pkgname}-${pkgver}
  make DESTDIR="${pkgdir}" PREFIX=/usr PRODUCTION=1 install
  install -Dm 644 README.md -t "${pkgdir}/usr/share/doc/${pkgname}"
  install -Dm 644 license.txt -t "${pkgdir}/usr/share/licenses/${pkgname}"
}

# vim: ts=2 sw=2 et:
